feat(logger): docs and runtime#16437
Conversation
🦋 Changeset detectedLatest commit: f40f166 The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
cc4db4d to
12635f0
Compare
ArmandPhilippot
left a comment
There was a problem hiding this comment.
Thanks Ema, the feature looks nice!
I hope I didn't got that wrong but, this is the changeset for when feat/logger will be merged in next, right? If not you can probably ignore most of my suggestions. 😅
Otherwise, I suggested a few changes to reuse the same pattern described in AD² and that we had on the previous features.
Do we need a next branch in docs or is it too early? Because it looks like we'll need a new experimental feature page for this!
Co-authored-by: Armand Philippot <git@armand.philippot.eu>
No, it will be merge into |
ArmandPhilippot
left a comment
There was a problem hiding this comment.
LGTM! I left a suggestion to add links to the docs and the RFC in the changeset. And I noticed we don't mention compose in the docs, we probably should.
| /** | ||
| * | ||
| */ |
There was a problem hiding this comment.
nit: Is this empty comment expected or you forgot to put something here?
| * }) | ||
| * ``` | ||
| */ | ||
| compose(...loggers: LoggerHandlerConfig[]): LoggerHandlerConfig { |
There was a problem hiding this comment.
I believe neither the documentation nor the changeset mentions this feature. Maybe for the changeset it's not important (ie. we can focus on the most important parts) but we probably want to mention it in the docs.
There was a problem hiding this comment.
I left it out in purpose here, I forgot to add to the docs, I will address this shortly
Co-authored-by: Armand Philippot <git@armand.philippot.eu>
Co-authored-by: Armand Philippot <git@armand.philippot.eu>
Changes
This PR add documentation to the public APIs of the logger. I also adds runtime APIs.
logHandlersfunctions, and added missing configurationAstro.loggerwithinfo,warnanderrorCloses AST-82
After speaking with Matthew, we agreed to remove the the vite dev server. The commit
d0d4df7(this PR) removes it and the importing of the logger is way simpler now.I tested it manually, specially compose.
Testing
Green CI. Added new tests.
Docs
/cc @withastro/maintainers-docs for feedback!
Added changeset, and docs to the public APIs
withastro/docs#13787